
package com.shanyin.framework.member.dao;

import org.apache.ibatis.annotations.Param;

import com.shanyin.framework.common.base.BaseDao;
import com.shanyin.framework.member.entity.SysUser;

/**
 * @author qing.yunhui 
 * @Since 2011-2018
 * @create 2018-05-23 14:35:32
 * @history
 */
public interface SysUserDao extends BaseDao<SysUser,Long>{
	
	/**
	 * <p>根据手机号查找用户</p>
	 * @param phone 手机号
	 * @return 
	 * */
	SysUser getSysUserByPhone(@Param("phone")String phone);
	
	/**
	 * <p>根据邮箱查找用户</p>
	 * @param email 邮箱
	 * @return 
	 * */
	SysUser getSysUserByEmail(@Param("email")String email);
	
	/**
	 * <p>根据邀请码查找用户</p>
	 * @param invitationCode 邀请码
	 * @return 
	 * */
	SysUser getSysUserByInvitationCode(@Param("invitationCode")String invitationCode);
	
	/**
	 * <p>根据邀请码统计记录条数</p>
	 * @param invitationCode 邀请码
	 * @return 
	 * */
	int queryCountByInvitationCode(@Param("invitationCode")String invitationCode);
	
}
